<style lang="scss" scoped>
.kepu {
    padding: 10px;
    h2{
        margin: 10px 0;
    }
    >p{
        font-size: 14px;
        color: #999;
        margin: 10px 0;
        span{
            margin-left: 190px;
        }
    }
    .zhuye{
        display: flex;
        position: relative;
        margin: 10px 0;
        img{
            margin: 0;
            width: 50px;
            height: 50px;
            border-radius: 50%;
        }
        .center{
            margin: 0 10px;
            line-height: 25px;
            .top{
                font-size: 20px;
                span{
                    font-size: 14px;
                    color: #999;
                }
            }
            .bottom{
                .tag{
                    font-size: 12px;
                    padding: 2px;
                    background-color: rgb(249, 236, 232);
                    color: orangered;
                    border-radius: 3px;
                }
                span{
                    font-size: 14px;
                    color: #999;
                }
            }
        }
        .right{
            position: absolute;
            right: 10px;
            top: 10px;
            .guanzhu{
                padding: 3px 5px;
                border: 1px solid rgb(35, 219, 44);
                color: rgb(35, 219, 44);
                font-size: 14px;
            }
        }
    }
    .content{
        font-size: 18px;
    }
}
</style>

<template>
    <div class="kepu">
        <h2>{{ item.title }}</h2>
        <p>阅读 {{ item.read_num }}<span> 2024-10-11 17:35:53 </span></p>
        <div class="zhuye">
            <img :src="item.doctor.image" alt="">
            <div class="center">
                <p class="top">
                    {{ item.doctor.name }}
                    <span>
                        {{ item.doctor.clinic_name }}
                        {{item.doctor.title}}
                    </span>
                </p>
                <p class="bottom">
                    <span class="tag">三甲</span>
                    <span>&nbsp;{{ item.doctor.hospital }}</span>
                </p>
            </div>
            <div class="right">
                <div class="guanzhu">
                    关注<van-icon name="arrow" />
                </div>
            </div>
        </div>
        <div class="content">
            <p v-html="item.content"></p>
        </div>
    </div>
</template>

<script setup lang="ts">
import { useRoute,useRouter } from 'vue-router'

const route = useRoute()
const router = useRouter()

const item = JSON.parse(route.query.item)
console.log(item);

</script>
<template>
    <div>
        科普详情
    </div>
</template>

<script setup>

</script>

<style lang="scss" scoped>

</style>
